<template>
    <div class="d-flex jc-between">
        <div>{{ weather.weather }}</div>
        <div>{{ weather.temperature }}摄氏度</div>
        <div>{{ weather.windDirection }}</div>
    </div>
</template>

<script setup>
import { ref } from "vue";
import{getWeather} from "@/js/Request/Weather.js"
const weather=ref({
    weather:"",
    temperature:null,
    windDirection:null
})
getWeather(res=>{
    if(res.data.code==200){
        weather.value.weather=res.data.weather1
        weather.value.temperature=res.data.temperature
        weather.value.windDirection=res.data.windDirection
    }
})

</script>

<style lang="scss" scoped>

</style>